<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<title></title>
<#include "/jspgou_sys/head.html"/>
<script type="text/javascript">
function optDelete() {
	if(Pn.checkedCount('ids')<=0) {
		alert("<@s.m 'error.checkRecord'/>");
		return;
	}
	if(!confirm("<@s.m 'global.confirm.delete'/>")) {
		return;
	}
	var f = document.getElementById('tableForm');
	f.action="o_delete.do";
	f.submit();
}

function getTableForm(){
	return document.getElementById("tableForm");
}


</script>
</head>
<body>
<div class="body-box">
<div class="rhead">
	<div class="rpos"><@s.m "global.position"/>: <@s.m "shop.function.product"/> - <@s.m "product.function"/> - <@s.m "global.list"/></div>
	
	<div class="clear"></div>
</div>
<div class="rhead">
	
	<div class="clear"></div>	
</div>
<div><input type="button" value="到货通知"></div>
<form id="tableForm" method="post">
<input type="hidden" name="pageNo" value="${pageNo!}"/>
<input type="hidden" name="ctgId" value="${ctgId!}"/>
<@p.table value=pagination;product,i,has_next><#rt/>
	<@p.column title="<input type='checkbox' onclick='Pn.checkbox(\"ids\",this.checked)'/>" width="20">
		<input type='checkbox' name='ids' value='${product.id}'/><#t/>
	</@p.column><#t/>

	<@p.column code="product.name" align="center"><a href="${product.url}" target="_blank">${product.name}</a></@p.column><#t/>
	<!-- <@p.column code="product.category" align="center">${product.category.name}</@p.column><#t/>
	<@p.column code="product.type" align="center">${product.type.name}</@p.column><#t/>
	<@p.column code="自营" align="center"><#if product.store??>否<#else>是</#if></@p.column><#t/>
	<@p.column code="product.salePrice" align="center"><#if product.productFashion??>${product.productFashion.salePrice!}<#else>${product.salePrice!}</#if></@p.column><#t/>
	<@p.column code="product.stockCount" align="center">${product.stockCount}</@p.column><#t/>
	<@p.column code="product.brand" align="center"><#if product.brand??>${(product.brand.name)!}</#if></@p.column><#t/>
	
	<@p.column code="上/下架" align="center"><#if product.onSale><a href="a_update.do?id=${product.id}&pageNo=${pageNo!}&ctgId==${(product.category.id)!}" >
	<input type="button" value="下架"/></a><#else> <a href="a_update.do?id=${product.id}&pageNo=${pageNo!}&ctgId==${(product.category.id)!}"><input type="button" value="上架"/></a></#if></@p.column><#t/>
	<@p.column code="product.onSale" align="center"><#if product.onSale><@s.m "global.true"/><#else><@s.m "global.false"/></#if></@p.column><#t/>
	
	<@p.column code="product.yushou" align="center"><#if product.yushou??><#if product.yushou><@s.m "global.true"/><#else><@s.m "global.false"/></#if></#if></@p.column><#t/>
	<@p.column code="global.operate" align="center">
		<a href="v_edit.do?id=${product.id}&pageNo=${pageNo!}&ctgId=${(product.category.id)!}"><@s.m "global.edit"/></a> | <#rt/>
		<a href="o_delete.do?ids=${product.id}&pageNo=${pageNo!}&ctgId=${(product.category.id)!}" onclick="if(!confirm('<@s.m "global.confirm.delete"/>')) {return false;}"><@s.m "global.delete"/></a><#t/>
	</@p.column><#t/> -->
</@p.table>
<!-- <div><input type="button" value="<@s.m "global.delete"/>" onclick="optDelete();"/> <input type="button" value="推荐" onclick="optTuijian();"/>
 <input type="button" value="上架" onclick="optShangjia();"> <input type="button" value="下架" onclick="optXiajia();"></div>
 -->
</form>
</div>
<#include "/common/alert_message.html"/>
</body>
</html>